package com.ricchieri.dao;

import java.util.List;

import org.hibernate.Criteria;

import com.ricchieri.dao.interf.ITripStopDao;
import com.ricchieri.filter.BasicFilter;
import com.ricchieri.model.TripStop;

public class TripStopDao extends GenericDao implements ITripStopDao {
	private static final long serialVersionUID = 9198864284400644103L;

	@Override
	@SuppressWarnings("unchecked")
	public List<TripStop> getAllTripStop(BasicFilter filter) {
		Criteria criteria = criteriaAllTripStop(filter);
		
		return criteria.list();
	}
	
	private Criteria criteriaAllTripStop(BasicFilter filter) {
		return super.criteriaAllBasic(filter, TripStop.class);
	}	
	
	@Override
	protected String getTableName() {
		return "tripStop";
	}
}
